<%@ page contentType="text/html;charset=UTF-8" isELIgnored="false" language="java" %>
<html>
<head>
    <title>Title</title>
</head>
<body>
    <%
        pageContext.setAttribute("name1","用户1");
        request.setAttribute("name2","用户2");
        session.setAttribute("name3","用户3");
        application.setAttribute("name4","用户4");

        pageContext.setAttribute("user1","user1",PageContext.PAGE_SCOPE);
        pageContext.setAttribute("user2","user2",PageContext.REQUEST_SCOPE);
        pageContext.setAttribute("user3","user3",PageContext.SESSION_SCOPE);
        pageContext.setAttribute("user4","user4",PageContext.APPLICATION_SCOPE);
    %>
    <hr>
    <%
        String name1 = (String)pageContext.getAttribute("name1");
        String name2 = (String)pageContext.getAttribute("name2");
        String name3 = (String)pageContext.getAttribute("name3");
        String name4 = (String)pageContext.getAttribute("name4");
        String name5 = (String)pageContext.getAttribute("name5");

        String user1 = (String)pageContext.getAttribute("user1");
        String user2 = (String)pageContext.getAttribute("user2");
        String user3 = (String)pageContext.getAttribute("user3");
        String user4 = (String)pageContext.getAttribute("user4");
        String user5 = (String)pageContext.getAttribute("user5");
    %>
    <h3>${name1}</h3>
    <h3>${name2}</h3>
    <h3>${name3}</h3>
    <h3>${name4}</h3>
    <h3>${name5}</h3>
    <hr>
    <h3>${user1}</h3>
    <h3>${user2}</h3>
    <h3>${user3}</h3>
    <h3>${user4}</h3>
    <h3>${user5}</h3>


</body>
</html>
